<template>
  <div>
    <input type="text" v-model="isbn" />
    <input type="text" v-model="title" />
    <button @click="requst">提交</button>
    <ul>
      <li v-for="(item, idnex) in list" :key="idnex">
        {{ item }}
      </li>
    </ul>
  </div>
</template>
<script>
module.exports = {
  data() {
    return {
      msg: "6666",
      title: "",
      isbn: "",
      list: [],
    };
  },
  mounted() {},
  methods: {
    requst() {
      axios.get(
          "http://192.168.0.228/api/v1/data/checkDuplicate",
          {
            headers: {
              "Content-Type": "application/x-www-form-urlencoded",
              Authorization: "5465465465654",
            },
            params: {
              isbn: this.isbn ,
              title: this.title
            },
          }, 
        )
        .then(res => {
          this.list = res.data.data;
        });
    },
  },
};
</script>
<style scoped>
h1 {
  color: red;
}
</style>